#ifndef GETMESSAGEINTERFACE_H
#define GETMESSAGEINTERFACE_H

#include <QObject>
#include <CommonHelper.h>
#include <Tcpclient.h>
#include <UdpClient.h>
#include <LogHelper.h>
#include <DbHelper.h>
#include <QSerialPortInfo>
#include <SpeechModuleThread.h>
#include <CommCommand.h>

class GetMessageInterface: public QObject
{
    Q_OBJECT
public:
    GetMessageInterface();
    ~GetMessageInterface();

    Q_INVOKABLE QVariantList getExperimentLog();
    Q_INVOKABLE QVariantList getExperimentLog(QString,QString);

    Q_INVOKABLE QString getDefaultExperimentName();
    Q_INVOKABLE QVariantMap getOtherExperimentInfo();

    Q_INVOKABLE int getDefaultConnectInfo();
    Q_INVOKABLE void connectEqu(QString,QString,QString);
    Q_INVOKABLE QVariantMap getConnectInfo(int);


    Q_INVOKABLE void setSpeechUseInfo(QString);
    Q_INVOKABLE void connectSpeechMode(QString);
    Q_INVOKABLE QStringList getSerialPort();
    Q_INVOKABLE int getSpeechUseInfo();

    Q_INVOKABLE QVector<double> getCPSData();
    Q_INVOKABLE QStringList getConsumablesName();
    Q_INVOKABLE QStringList getExperimentNameByConsumables(QString);

    Q_INVOKABLE QString unitConversion(QString,QString,QString);
    Q_INVOKABLE QString unitConversionBySerial(QString,QString,QString,QString);

    Q_INVOKABLE QStringList getDefaultExeConfig();
private:
    CommonHelper *common;
    Loghelper *log;
    TcpClient *tcpClient;
    UdpClient *udpClient;

};

#endif // GETMESSAGEINTERFACE_H
